# encoding: utf-8

class ItemRecommend < ActiveRecord::Base
  belongs_to :recommend_subject
  belongs_to :recommendable, :polymorphic => true
  
  validates_presence_of :recommend_subject_id, :recommendable_id
  validates_uniqueness_of :recommendable_id, :scope => :recommend_subject_id, :message => '不能重复添加'

end
